#ifndef GRAPHICS_H
#define GRAPHICS_H

#include "Vector3D.h"
#include "cAnimate.h"
#include "cCamera2D.h"

class cGraphics {
	public:
		//Constructor for Graphics
		cGraphics();

		//Destructor for Graphics
		~cGraphics();

		//Creates a camera for the screen
		cCamera2D createCamera(D3DXVECTOR3 eyePosition, D3DXVECTOR3 targetPosition, D3DXVECTOR3 upVector);

		//Begins the render process for the sprites
		void beginSpriteRender(DWORD flags);

		//Batch the sprites for the render
		void flushSprites();

		//Ends the render process for the sprites
		void endSpriteRender();

		//Gathers the sprite information and draws it to the screen
		void drawSprite(cSprite *sprite);

		//Gathers the information to draw the sprite center to the screen
		void drawSpriteC(cSprite* sprite, Vector3D center);

		//Gathers the animation information and draws it to the screen
		void drawAnimation(cAnimation *animation);

		//Provides the information for the rendering position of the sprite
		//this will then assume the location in the world view.
		void SetTranformation(const D3DXMATRIX &view);

		//Recovers the ID3DXSprite device
		void onResetDevice();

		//Restores the Device from being lost
		void onLostDevice();
	private:
		//The Interface for the 2D rendering
		ID3DXSprite			*m_pD3DXSprite;
};
#endif